<%String nav="test"; %>
<%@ page contentType="text/html; charset=UTF-8" %>
<%@ page import="com.google.appengine.api.users.*" %>
<%
  UserService userService = UserServiceFactory.getUserService();
  User user = userService.getCurrentUser();
  String authURL = (user != null) ? userService.createLogoutURL(request.getRequestURI()): userService.createLoginURL(request.getRequestURI());
%><!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8" />
    <title>Show Minifier - Visual web page compressor</title>
    <link type="text/css" rel="stylesheet" href="/css/project.css" />
  </head>
  <body>
  <div class="page">
  <div class="head">
    <div class="signin">
      <% if (user != null) { %>
         <%= user.getEmail() %> | <a href="/settings">settings</a> | 
      <% } %>
      <a href="<%= authURL %>">
        <% if (user != null) { %>Log out<% } else  { %>Log in<% } %>
      </a>
    </div>
    <h1>
        Show Minifier
    </h1>
    <ul class="nav">
    	<li><a <% if(nav.equals("home")){%>class="selected" <%}%>href="/">Home</a>
        <li><a <% if(nav.equals("test")){%>class="selected" <%}%>href="/test">New Test</a>
        <li><a <% if(nav.equals("result")){%>class="selected" <%}%>href="/result">Test Result</a>
        <li><a href="http://code.google.com/p/showminifier">Download</a>
    	<!--li><a <% if(nav.equals("performance")){%>class="selected"<%}%> href="/performance">Performance</a-->
    	<!--li><a <% if(nav.equals("help")){%>class="selected"<%}%> href="/help">Help</a-->
        <li><a href="http://groups.google.com/group/showminifier">Forums</a>
    </ul>
    </div>
<div class="body">
	<h1>Some oerror occued!</h1>
<%
String key = (String)request.getAttribute("errors");
%>
	<div class="error">
		<img src="/img/error.png"><%= key %>
	</div>
</div>
<%@ include file="include/foot.jsp"%>
</div>
